import http from '../utils/request';

// 登录接口
export function loginRequest(adminname: string, password: string) {
  return http({
    url: '/admin/admin/login',
    method: 'post',
    data: {
      adminname,
      password
    }
  });
}
//添加管理员接口
export function adminAddRequest(adminname: string, password: string) {
  return http({
    url: '/admin/admin/add',
    method: 'post',
    data: {
      adminname,
      password,
    }
  });
}
//管理员信息接口
export function adminRequest() {
  return http({
    url: '/admin/detail',
    method: 'get',
  });
}
//管理员列表接口
export function adminListRequest() {
  return http({
    url: '/admin/list',
    method: 'get',
  });
}
//用户总数量接口
export function userNumberRequest() {
  return http({
    url: '/admin/statistic/user',
    method: 'get',
  });
}
